<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <div id="app">

        <h2>v-html</h2>
        <h3 v-html="testhtml"></h3>
        <h1 v-text="count"></h1>
        <button v-on:click="OnClick">点击+1</button>
        <button v-on:click="DoubleAdd">点击+2</button>
    </div>
    <script src="./js/Dep.js"></script>
    <script src="./js/Watcher.js"></script>
    <script src="./js/Compiler.js"></script>
    <script src="./js/observer.js"></script>
    <script src="./js/MyVue.js"></script>
    <script>
        let vm = new Vue({
            el: '#app',
            data: {
                testhtml: '<em>我是新的html</em>',
                msg: "aa",
                count: 0
            },
            methods: {
                OnClick: function() {
                    this.count++
                },
                DoubleAdd: function() {
                    this.count += 2;
                }
            }
        })
    </script>
</body>

</html>